﻿
(function ($) {
    $.fn.link = function (option) {
        option = $.extend({
        //text: null,
        //closeable: false,
        //href:null,
        //postdata: {}
    }, option);
    return this.each(function () {
        $(this).click(function () {
            var target = $(this).attr("target");
            if (target == "navtab") {
                link_navtab($(this));
                return false;
            }
            if (target == "dialog") {
                link_dialog($(this));
                return false;
            }
            if (target == "ajaxpostform") {
                link_ajaxpostform($(this));
                return false;
            }
            if (target == "calljs") {
                link_calljs($(this));
                return false;
            }
        });
    });
}
})(jQuery);